﻿using System.Web.Mvc;
using Dexter.Logger.Contracts;
using Dexter.Services;
using Dexter.Web.Mvc.ViewModel.Backoffice.ViewsData.MessageController;
using Dexter.Web.Utils;

namespace Dexter.Web.Mvc.Controllers.Backoffice {
	[Authorize]
	public class MessageController : BackOfficeControllerBase {
		public MessageController ( IConfigurationService configurationService , IWebUtils webUtils , ILogger logger , IUrlBuilder urlBuilder , IContactService contactService ) : base ( configurationService , webUtils , logger , urlBuilder , contactService ) {}

		[AcceptVerbs(HttpVerbs.Get)]
		public ActionResult Positive ( string id ) {
			return View ( new MessageViewData {
				Message = ( string )HttpContext.GetGlobalResourceObject ( "Messages", id )
			} );
		}

		[AcceptVerbs ( HttpVerbs.Get )]
		public ActionResult Negative ( string id ) {
			return View ( new MessageViewData {
				Message = ( string )HttpContext.GetGlobalResourceObject ( "Messages", id )
			} );
		}
	}
}